package com.jeff.android.lab.module.annotation;

import com.jeff.android.lab.BaseRecyclerViewFragment;
import com.jeff.android.lab.module.annotation.compile.CompileAnnotationFragment;
import com.jeff.android.lab.module.annotation.runtime.RuntimeAnnotationFragment;
import com.jeff.android.lab.util.RouterUtil;

import java.util.ArrayList;
import java.util.List;

public class AnnotationMainFragment extends BaseRecyclerViewFragment {

    @Override
    protected List<String> getData() {
        return new ArrayList<String>() {
            {
                add("RuntimeAnnotation");
                add("CompileAnnotation");
            }
        };
    }

    @Override
    protected void launch(String widget) {
        if ("RuntimeAnnotation".equals(widget)) {
            RouterUtil.launchFragmentActivity(getContext(), RuntimeAnnotationFragment.class);
        } else if ("CompileAnnotation".equals(widget)) {
            RouterUtil.launchFragmentActivity(getContext(), CompileAnnotationFragment.class);
        }
    }

}
